package com.shj.em.aa.mapper;

import com.baomidou.mybatisplus.plugins.Page;
import com.shj.em.aa.dto.RoleSearchDTO;
import com.shj.em.aa.entity.Role;
import com.baomidou.mybatisplus.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;
import java.util.Map;
import java.util.Set;

/**
 * <p>
 * 角色 Mapper 接口
 * </p>
 *
 * @author Shen Huang Jian
 * @since 2018-06-25
 */
@Mapper
public interface RoleMapper extends BaseMapper<Role> {

    Set<Role> findRolesByUserLoginId(String userLoginId);

    List<Role> findRolesByUserId(Long userId);

    /**
     * 分页查询
     * @param page 分页信息
     * @return
     */
    List<Role> queryRolePage(Page<Role> page, RoleSearchDTO searchDTO);
}
